part of my_base_lib;
class LanguageUtils {
  // 获取本地存储的配置语言


  static String getLanguageType() {
    //en,zh
    String? language = SpUtils.getPublicString("language_type");
    if (language!=null) {
      return language;
    }
    return "zh";
  }

  /// 切换语言
  changeLanguage(String languageType) async {
    SpUtils.savePublicString("language_type", languageType);
    //S.load(Locale(languageType));
  /*  var locale = Locale(languageType);
    /// 更新语言
    await Get.updateLocale(locale);
    /// 存储本地语言配置
    await CommonSpUtil.saveLanguageType(languageStr);*/
  }
}